﻿namespace SuperMarieApi.App.Controllers.Framework.Common
{
    using System;

    using SuperMarieApi.App.Controllers.Framework.Resource;

    public static class Guard
    {
        public static void IsNotNull(object parameter, string parameterName)
        {
            if (parameter == null)
            {
                throw new ArgumentNullException(parameterName, ResFramework.CanNotBeNull.FormatWith(new object[] { parameterName }));
            }
        }

        public static void IsNotNullOrEmpty(string parameter, string parameterName)
        {
            if (parameter.IsNullOrEmpty())
            {
                throw new ArgumentException(ResFramework.CanNotBeNullOrEmpty.FormatWith(parameterName));
            }
        }
    }

 

}
